<?php namespace Admin\Controller;
use Hdphp\Controller\Controller;
//公用控制器
class CommonController extends Controller{
	public function __init(){
		$this->auth();
	}
	//验证登录
	public function auth(){
		//判断用户是否登录
		if(!isset($_SESSION['admin_id']) || !isset($_SESSION['account'])){
			//跳转到登录页面
			go(U('Login/index'));
		}
	}
}

 ?>